package com.chu.seviece.impl;

import com.chu.bean.Menu;
import com.chu.bean.Role;
import com.chu.dao.MenuDao;
import com.chu.dao.RoleDao;
import com.chu.seviece.ManyToManyService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service("manyService")
public class ManyToManyServiceImpl implements ManyToManyService {

    @Autowired
    private RoleDao roleDao;
    @Autowired
    private MenuDao menuDao;

    @Override
    public List<Role> findAllRole() {
        return roleDao.findAll();
    }

    @Override
    public List<Menu> findAllMenu() {
        return menuDao.findAll();
    }
}
